package com.ppx.life.dao.vo;

import java.text.SimpleDateFormat;
import java.util.Date;

public class Conversation {

    SimpleDateFormat df = new SimpleDateFormat("MM-dd HH:mm:ss");//设置日期格式
    String date = df.format(new Date());// new Date()为获取当前系统时间，也可使用当前时间戳

    private int code = 0;
    private String message = "success";
    private String request_time = date;
    private Object data;

    public Conversation(){}

    public Conversation(String message) {
        this.message = message;
    }
    public Conversation(Object data) {
        this.data = data;
    }
    public Conversation(Throwable e){
        this.code = 1;
        this.message=e.getMessage();
    }


    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public String getRequest_time() {
        return request_time;
    }

    public void setRequest_time(String request_time) {
        this.request_time = request_time;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }

}
